import { isScalar as u } from '../nodes/identity.js';
function a(s, r, t) {
  const { uniqueKeys: n } = s.options;
  if (n === !1) return !1;
  const i =
    typeof n == 'function'
      ? n
      : (e, o) =>
          e === o ||
          (u(e) &&
            u(o) &&
            e.value === o.value &&
            !(e.value === '<<' && s.schema.merge));
  return r.some(e => i(e.key, t));
}
export { a as mapIncludes };
